<div id="boxes_wrapper">
<div class="box_wrapper">  
<div class="box_title">Tag:</div>

<?php echo form_open('write/dowrite'); ?>

<p id="p_article_timestamp">
<?php if($article->article_abstract) { ?>
<table><tr>
<td>Article timestamp:</td><td><input name="article_timestamp" id="article_timestamp" value="<?php echo $article->timestamp; ?>"/> 
<input type=button value="select" onclick="displayDatePicker('article_timestamp');"/></td></tr></table>
<?php } else { ?>
<a href="javascript:defineTimestamp()">Create a TimeStamp</a>
<?php } ?></p>

<p id="p_article_tags">
<?php if($article->tags) { ?>
<table><tr>
<td>Tags*:</td><td> <?php echo $article->taglist("</td></tr><tr><td/><td>"); ?>
</td></tr><tr><td/><td>
<input type=button value="add" onclick="add_tag();"/>
</td></tr></table>
<?php } else { ?>
<a href="javascript:add_tag()">Add SubjectTags</a>
<?php } ?></p>

<p id="p_article_peopletags">
<?php if($article->peopletags) { ?>
<table><tr>
<td>Peopletags*:</td><td> <?php echo $article->peopletaglist("</td></tr><tr><td/><td>"); ?>
</td></tr><tr><td/><td>
<input type=button value="add" onclick="add_peopletag();"/>
</td></tr></table>
<?php } else { ?>
<a href="javascript:add_peopletag()">Add PeopleTags</a>
<?php } ?></p>

<p id="p_article_geostamps">
<?php if($article->geostamps) { ?>
<table><tr><td>
Geostamps*:</td><td><?php echo $article->geostamplist("</td></tr><tr><td/><td>"); ?>
</td></tr><tr><td/><td>
<input type=button value="add" onclick="add_geostamp();"/>
</td></tr></table>
<?php } else { ?>
<a href="javascript:add_geostamp()">Add GeoTags</a>
<?php } ?></p>
<hr style=" color: #ccccee;"/>

<div class="box_title">Document:</div>

<p><a href="javascript:add_document()">Photos or images</a></p>
<p><a href="javascript:add_document()">Videos</a></p>
<p><a href="javascript:add_document()">Audio recordings</a></p>
<p><a href="javascript:add_document()">Documents</a></p>

<hr style=" color: #ccccee;"/>

<div class="box_title">Contextualize:</div>

<?php if($article->story && $article->story->valid()) { ?>
<table><tr><td>This article belongs to the story:</td>
        <td><?php echo $article->story->story_title_link(); ?>.</td></tr></table>
<?php } else { ?>
<p><a href="javascript:add_to_story()">Add to story</a></p>
<?php } ?>

<p id="p_article_links">
<?php if($article->links) { ?>
<table><tr><td>
External links:</td><td><?php echo $article->linkslist("</td></tr><tr><td/><td>"); ?>
</td></tr><tr><td/><td>
<input type=button value="add" onclick="add_link();"/>
</td></tr></table>
<?php } else { ?>
<a href="javascript:add_link()">Add an external link</a>
<?php } ?></p>

<p id="p_article_related">
<?php if($article->related_articles) { ?>
<table><tr><td>
'See also' articles:</td><td><?php echo $article->rel_article_list("</td></tr><tr><td/><td>"); ?>
</td></tr><tr><td/><td>
<input type=button value="add" onclick="add_related_article();"/>
</td></tr></table>
<?php } else { ?>
<p><a href="javascript:add_related_article()">Add an Oximity article as 'see also'</a></p>
<?php } ?></p>




<hr style=" color: #ccccee;"/>

<div class="box_title">Share:</div>
<p><a href="">Facebook</a></p>
<p><a href="">Twitter</a></p>
<p><a href="">LinkedIn</a></p>
<p><a href="">Email to my group</a></p>
<p id="debug"/>
</form>
</div></div>